home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_sol_horusswitch.cog < prev    next >
Text File  |  1999-11-15  |  1KB  |  52 lines

  1. # Jones 3D Cog Script
  2. #
  3. # SOL_HorusSwitch.cog
  4. #
  5. # [TRM]
  6. #
  7. # (C) 1997 LucasArts Entertainment Co. All Rights Reserved
  8. # ========================================================================================
  9.  
  10. symbols
  11.  
  12.     message     entered
  13.     
  14.     thing       car         local
  15.     
  16.     surface     before      mask=0x404
  17.     surface     after       mask=0x404
  18.     surface     track
  19.         
  20. end
  21.  
  22. # ========================================================================================
  23. code
  24.  
  25. entered:
  26.  
  27.     car = GetSourceRef();
  28.  
  29.     if(BitTest(GetPhysicsFlags(car), 0x01000000))
  30.     {
  31.         if(GetSenderRef() == before)
  32.         {
  33.             # minecar can go straight
  34.             #Print("go straight");
  35.             SetSurfaceFlags(track, 0x4000);
  36.         }
  37.             
  38.         if(GetSenderRef() == after)
  39.         {
  40.             # minecar can backup and drive to horus door
  41.             #Print("turn off");
  42.             ClearSurfaceFlags(track, 0x4000);
  43.         }
  44.     }
  45.     
  46.     return;
  47.  
  48. # ========================================================================================
  49.  
  50. end
  51.  
  52.